import Cookies from 'js-cookie'

//Token
const TokenKey = 'DyMobileCumAPI_Token'
export function getToken() {
  return Cookies.get(TokenKey)
}
export function setToken(token) {
  return Cookies.set(TokenKey, token,{ expires:101365 })
}
export function removeToken() {
  return Cookies.remove(TokenKey)
}

//用户
export function getUName() {
  return decodeURIComponent(  Cookies.get("DyMobileCumAPI_UName") || ""  )
}
export function getUCode() {
  return Cookies.get("DyMobileCumAPI_UCode")
}
export function getUId() {
  return Cookies.get("DyMobileCumAPI_Uid")
}
export function getDefProjID() {
  return Cookies.get("DyMobileCumAPI_DefProjID")
}
export function getAvatar() {
  return Cookies.get("DyMobileCumAPI_Avatar")
}
